<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
	<head>
		<title>SWFObject 2 static publishing example page</title>
		<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
		<script type="text/javascript" src="../../apps/core_dom_xvideo.js"></script>
		<script type="text/javascript" src="../../3rd/swfobject/swfobject.js"></script>
		<script type="text/javascript" src="player_helper.js"></script>
	</head>
		<script>
			var player =  _js_PlayerHelper.create("myContent",{"vid":"test1"});
			player.play("test");

			player.on("*", function(evt){
				var obj = ObjectH.dump(evt, ["cid","vid"]);
				W("#logger").appendChild("<span>"+evt.type+ObjectH.stringify(obj)+" </span>");
				W("#watcher").setHtml("Event Time:" + new Date());
			});	
			player.on("up", function(){
				alert("up");
			});
		</script>
	<body>
		<div>
			<div id = "logger">
			
			</div>
			<div id = "watcher">
			</div>
			<button id="swap">Test AudioSwap</button>
			<button id="play">Test Random Play</button>
			<div id="myContent">
				<h1>Alternative content</h1>
				<p><a href="http://www.adobe.com/go/getflashplayer"><img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" /></a></p>
			</div>
		</div>
		<script>
			W("#swap").on("click", function(){
				player.swapAudio(Math.random());
			});
			W("#play").on("click", function(){
				player.play(Math.random());
			});
		</script>
	</body>
</html>
